.class Lcom/waiqin365/lightapp/syorder/product/k;
.super Landroid/os/Handler;


# instance fields
.field private a:Ljava/lang/ref/WeakReference;


# direct methods
.method public constructor <init>(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)V
    .locals 1

    invoke-direct {p0}, Landroid/os/Handler;-><init>()V

    new-instance v0, Ljava/lang/ref/WeakReference;

    invoke-direct {v0, p1}, Ljava/lang/ref/WeakReference;-><init>(Ljava/lang/Object;)V

    iput-object v0, p0, Lcom/waiqin365/lightapp/syorder/product/k;->a:Ljava/lang/ref/WeakReference;

    return-void
.end method


# virtual methods
.method public handleMessage(Landroid/os/Message;)V
    .locals 5

    iget-object v0, p0, Lcom/waiqin365/lightapp/syorder/product/k;->a:Ljava/lang/ref/WeakReference;

    invoke-virtual {v0}, Ljava/lang/ref/WeakReference;->get()Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;

    if-nez v0, :cond_1

    :cond_0
    :goto_0
    return-void

    :cond_1
    invoke-virtual {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->dismissProgressDialog()V

    iget v1, p1, Landroid/os/Message;->what:I

    packed-switch v1, :pswitch_data_0

    goto :goto_0

    :pswitch_0
    iget-object v1, p1, Landroid/os/Message;->obj:Ljava/lang/Object;

    check-cast v1, Lcom/waiqin365/lightapp/syorder/b/a/n;

    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->d(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)Lcom/waiqin365/lightapp/dailyreport/view/CustomListview;

    move-result-object v2

    const-string/jumbo v3, ""

    invoke-virtual {v2, v3}, Lcom/waiqin365/lightapp/dailyreport/view/CustomListview;->a(Ljava/lang/String;)V

    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->d(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)Lcom/waiqin365/lightapp/dailyreport/view/CustomListview;

    move-result-object v2

    invoke-virtual {v2}, Lcom/waiqin365/lightapp/dailyreport/view/CustomListview;->d()V

    invoke-virtual {v1}, Lcom/waiqin365/lightapp/syorder/b/a/n;->b()Z

    move-result v2

    if-eqz v2, :cond_6

    const-string/jumbo v2, "1"

    iget-object v3, v1, Lcom/waiqin365/lightapp/syorder/b/a/n;->b:Ljava/lang/String;

    invoke-virtual {v2, v3}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v2

    if-eqz v2, :cond_6

    iget-boolean v2, v1, Lcom/waiqin365/lightapp/syorder/b/a/n;->d:Z

    if-eqz v2, :cond_2

    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->e(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)Ljava/util/List;

    move-result-object v2

    invoke-interface {v2}, Ljava/util/List;->size()I

    move-result v2

    if-nez v2, :cond_2

    iget-object v2, v1, Lcom/waiqin365/lightapp/syorder/b/a/n;->f:Ljava/util/List;

    invoke-interface {v2}, Ljava/util/List;->size()I

    move-result v2

    if-nez v2, :cond_2

    const-string/jumbo v1, "\u6ca1\u6709\u627e\u5230\u76f8\u5173\u5546\u54c1\uff01"

    const/4 v2, 0x0

    invoke-static {v0, v1, v2}, Lcom/waiqin365/lightapp/view/dk;->a(Landroid/content/Context;Ljava/lang/CharSequence;I)V

    invoke-virtual {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->getIntent()Landroid/content/Intent;

    move-result-object v1

    const-string/jumbo v2, "search"

    invoke-virtual {v1, v2}, Landroid/content/Intent;->getStringExtra(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v1

    invoke-static {v1}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v1

    if-nez v1, :cond_0

    invoke-virtual {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->finish()V

    goto :goto_0

    :cond_2
    iget-boolean v2, v1, Lcom/waiqin365/lightapp/syorder/b/a/n;->e:Z

    if-eqz v2, :cond_3

    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->d(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)Lcom/waiqin365/lightapp/dailyreport/view/CustomListview;

    move-result-object v2

    const-string/jumbo v3, ""

    invoke-virtual {v2, v3}, Lcom/waiqin365/lightapp/dailyreport/view/CustomListview;->a(Ljava/lang/String;)V

    :goto_1
    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->e(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)Ljava/util/List;

    move-result-object v2

    invoke-interface {v2}, Ljava/util/List;->size()I

    move-result v2

    if-nez v2, :cond_4

    iget-object v2, v1, Lcom/waiqin365/lightapp/syorder/b/a/n;->f:Ljava/util/List;

    invoke-interface {v2}, Ljava/util/List;->size()I

    move-result v2

    if-nez v2, :cond_4

    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->f(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)V

    :goto_2
    iget-object v2, v1, Lcom/waiqin365/lightapp/syorder/b/a/n;->f:Ljava/util/List;

    invoke-interface {v2}, Ljava/util/List;->size()I

    move-result v2

    const v3, 0x1312d00

    if-ne v2, v3, :cond_5

    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->d(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)Lcom/waiqin365/lightapp/dailyreport/view/CustomListview;

    move-result-object v2

    invoke-virtual {v2}, Lcom/waiqin365/lightapp/dailyreport/view/CustomListview;->g()V

    :goto_3
    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->e(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)Ljava/util/List;

    move-result-object v2

    invoke-interface {v2}, Ljava/util/List;->clear()V

    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->h(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)Landroid/widget/TextView;

    move-result-object v2

    new-instance v3, Ljava/lang/StringBuilder;

    invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V

    iget-object v4, v1, Lcom/waiqin365/lightapp/syorder/b/a/n;->f:Ljava/util/List;

    invoke-interface {v4}, Ljava/util/List;->size()I

    move-result v4

    invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v3

    const-string/jumbo v4, ""

    invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v3

    invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v3

    invoke-virtual {v2, v3}, Landroid/widget/TextView;->setText(Ljava/lang/CharSequence;)V

    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->e(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)Ljava/util/List;

    move-result-object v2

    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->e(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)Ljava/util/List;

    move-result-object v3

    invoke-interface {v3}, Ljava/util/List;->size()I

    move-result v3

    iget-object v1, v1, Lcom/waiqin365/lightapp/syorder/b/a/n;->f:Ljava/util/List;

    invoke-interface {v2, v3, v1}, Ljava/util/List;->addAll(ILjava/util/Collection;)Z

    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->i(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)Lcom/waiqin365/lightapp/syorder/product/a/m;

    move-result-object v0

    invoke-virtual {v0}, Lcom/waiqin365/lightapp/syorder/product/a/m;->notifyDataSetChanged()V

    goto/16 :goto_0

    :cond_3
    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->d(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)Lcom/waiqin365/lightapp/dailyreport/view/CustomListview;

    move-result-object v2

    invoke-virtual {v2}, Lcom/waiqin365/lightapp/dailyreport/view/CustomListview;->d()V

    goto :goto_1

    :cond_4
    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->g(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)V

    goto :goto_2

    :cond_5
    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->d(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)Lcom/waiqin365/lightapp/dailyreport/view/CustomListview;

    move-result-object v2

    invoke-virtual {v2}, Lcom/waiqin365/lightapp/dailyreport/view/CustomListview;->f()V

    goto :goto_3

    :cond_6
    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->b(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)Lcom/waiqin365/lightapp/syorder/product/b/a;

    move-result-object v2

    iget-object v2, v2, Lcom/waiqin365/lightapp/syorder/product/b/a;->d:Lcom/waiqin365/lightapp/syorder/product/b/b;

    iget-object v2, v2, Lcom/waiqin365/lightapp/syorder/product/b/b;->d:Ljava/lang/String;

    invoke-static {v2}, Ljava/lang/Integer;->parseInt(Ljava/lang/String;)I

    move-result v2

    const/4 v3, 0x1

    if-le v2, v3, :cond_7

    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->b(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)Lcom/waiqin365/lightapp/syorder/product/b/a;

    move-result-object v2

    iget-object v2, v2, Lcom/waiqin365/lightapp/syorder/product/b/a;->d:Lcom/waiqin365/lightapp/syorder/product/b/b;

    new-instance v3, Ljava/lang/StringBuilder;

    invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V

    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->b(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)Lcom/waiqin365/lightapp/syorder/product/b/a;

    move-result-object v4

    iget-object v4, v4, Lcom/waiqin365/lightapp/syorder/product/b/a;->d:Lcom/waiqin365/lightapp/syorder/product/b/b;

    iget-object v4, v4, Lcom/waiqin365/lightapp/syorder/product/b/b;->d:Ljava/lang/String;

    invoke-static {v4}, Ljava/lang/Integer;->parseInt(Ljava/lang/String;)I

    move-result v4

    add-int/lit8 v4, v4, -0x1

    invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v3

    const-string/jumbo v4, ""

    invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v3

    invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v3

    iput-object v3, v2, Lcom/waiqin365/lightapp/syorder/product/b/b;->d:Ljava/lang/String;

    :cond_7
    iget-object v2, v1, Lcom/waiqin365/lightapp/syorder/b/a/n;->c:Ljava/lang/String;

    invoke-static {v2}, Lcom/fiberhome/gaea/client/d/k;->i(Ljava/lang/String;)Z

    move-result v3

    if-eqz v3, :cond_8

    const-string/jumbo v2, "\u8fde\u63a5\u670d\u52a1\u5668\u5931\u8d25\uff0c\u8bf7\u91cd\u8bd5\uff01"

    :cond_8
    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->e(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)Ljava/util/List;

    move-result-object v3

    invoke-interface {v3}, Ljava/util/List;->size()I

    move-result v3

    if-nez v3, :cond_9

    iget-object v1, v1, Lcom/waiqin365/lightapp/syorder/b/a/n;->f:Ljava/util/List;

    invoke-interface {v1}, Ljava/util/List;->size()I

    move-result v1

    if-nez v1, :cond_9

    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->f(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)V

    :goto_4
    invoke-virtual {v0, v2}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->showToast(Ljava/lang/String;)V

    goto/16 :goto_0

    :cond_9
    invoke-static {v0}, Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;->g(Lcom/waiqin365/lightapp/syorder/product/SyProductSearchActivityNew;)V

    goto :goto_4

    nop

    :pswitch_data_0
    .packed-switch 0x3f5
        :pswitch_0
    .end packed-switch
.end method
